﻿<%@ Assembly Name="$SharePoint.Project.AssemblyFullName$" %>
<%@ Assembly Name="Microsoft.Web.CommandUI, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register TagPrefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls"
    Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register TagPrefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register TagPrefix="asp" Namespace="System.Web.UI" Assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" %>
<%@ Import Namespace="Microsoft.SharePoint" %>
<%@ Register TagPrefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages"
    Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="PromoteInfoUserControl.ascx.cs"
    Inherits="com.stifel.BranchMgmt.WebParts.PromoteInfo.PromoteInfoUserControl" %>
<%--START: CSS and JS --%>
<link type="text/css" rel="Stylesheet" media="all" href="/_layouts/com.stifel.BranchMgmt/stylesheets/style.css" />
<script language="javascript" type="text/javascript" src="/_layouts/com.stifel.BranchMgmt/scripts/jquery-1.4.1.min.js"></script>
<script language="javascript" type="text/javascript" src="/_layouts/com.stifel.BranchMgmt/scripts/jquery-base64encoding.js"></script>
<script language="javascript" type="text/javascript" src="/_layouts/com.stifel.BranchMgmt/scripts/jquery-custom.js"></script>
<script language="javascript" type="text/javascript" src="/_layouts/com.stifel.BranchMgmt/scripts/js-custom.js"></script>
<script language="javascript" type="text/javascript">
// <![CDATA[
    function closeWin() {
        window.close();
    }
// ]]>
</script>
<style type="text/css">
    
</style>
<%--END: CSS and JS --%>
<%--START: http://msdn.microsoft.com/en-us/library/ee231545.aspx--%>
<asp:HiddenField ID="SharePoint_Project_FileNameWithoutExtension" Value="$SharePoint.Project.FileNameWithoutExtension$"
    runat="server" />
<asp:HiddenField ID="SharePoint_Project_AssemblyFullName" Value="$SharePoint.Project.AssemblyFullName$"
    runat="server" />
<asp:HiddenField ID="SharePoint_ProjectItem_Name" Value="$SharePoint.ProjectItem.Name$"
    runat="server" />
<%--END: http://msdn.microsoft.com/en-us/library/ee231545.aspx--%>
<asp:UpdatePanel ID="uiAjax" runat="server" UpdateMode="Always">
    <ContentTemplate>
        <asp:Panel ID="uiSummrizedInfo" runat="server">
        </asp:Panel>
        <asp:Panel ID="uiInfo" runat="server">
            <div id="uiNavigation" runat="server">
                <asp:Button ID="uiBtnBasics" Text="Basics" runat="server" CommandArgument="uiBasics"
                    OnClick="uiNavigationTab_Click" ToolTip="Basic Branch Information" CssClass="t" />
            </div>
            <asp:MultiView ID="uiView" runat="server" OnLoad="uiView_OnLoad">
                <asp:View ID="uiBasics" runat="server" OnActivate="uiBasics_Activate" OnDeactivate="uiBasics_Deactivate">
                    <div id="uiDivBasics_NA" style="height: 390px;" runat="server" visible="false">
                        <asp:Literal ID="uiLblBasics_NA" runat="server"></asp:Literal>
                    </div>
                    <div id="uiDivBasics" style="height: 390px;" runat="server" visible="true">
                        <table>
                            <tr>
                                <td style="width: 20%;">
                                    <asp:Label ID="uiLblBranchId" Text="Branch ID:" runat="server" CssClass="ms-vb" />
                                </td>
                                <td style="width: 25%;">
                                    <asp:Label ID="uiBranchId" runat="server" CssClass="ms-vb" />
                                </td>
                                <td valign="top" rowspan="3">
                                    <asp:Label ID="uiLblAddress" Text="Address:" runat="server" CssClass="ms-vb" />
                                </td>
                                <td valign="top" rowspan="3">
                                    <asp:Label ID="uiLblValAddress" runat="server"></asp:Label>
                                    <%--<asp:PlaceHolder ID="uiAddress" runat="server" />--%>
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 20%;">
                                    <asp:Label ID="uiLblSiteId" Text="Site ID:" runat="server" CssClass="ms-vb" />
                                </td>
                                <td style="width: 25%;">
                                    <asp:Label ID="uiSiteId" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    &nbsp;
                                </td>
                                <td>
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    <asp:Label ID="uiLblSpeedDial" Text="Speed Dial:" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    <asp:Label ID="uiSpeedDial" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    &nbsp;
                                </td>
                                <td>
                                    &nbsp;
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    <asp:Label ID="uiLblThompsonIdPrefix" Text="Thompson ID (prefix):" runat="server"
                                        CssClass="ms-vb" />
                                </td>
                                <td>
                                    <asp:Label ID="uiThompsonIdPrefix" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    <asp:Label ID="uiLblTimeZone" Text="Time Zone:" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    <asp:Label ID="uiTimeZone" runat="server" CssClass="ms-vb" />
                                </td>
                            </tr>
                            <tr>
                                <td valign="top">
                                    <asp:Label ID="uiLblBroadcastIp" Text="Broadcast IPs:" runat="server" CssClass="ms-vb" />
                                </td>
                                <td valign="top">
                                    <asp:Label ID="uiBroadcastIp" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    <asp:Label ID="uiLblBranchType" Text="Branch Type:" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    <asp:Label ID="uiBranchType" runat="server" CssClass="ms-vb" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    <asp:Label ID="uiLblPriceServer" Text="Price Server:" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    <asp:Label ID="uiPriceServer" runat="server" CssClass="ms-vb" />
                                </td>
                                <td>
                                    &nbsp;
                                </td>
                                <td>
                                    &nbsp;
                                </td>
                            </tr>
                        </table>
                        <table>
                            <tr>
                                <td>
                                    <asp:Repeater ID="uiBusinessUnit_Repeater" runat="server">
                                        <HeaderTemplate>
                                            <table>
                                                <tr>
                                                    <td style="width: 20%; padding-left: 2px;">
                                                        <h5 class="ms-standardheader ms-WPTitle">
                                                            Business Unit</h5>
                                                    </td>
                                                    <td style="width: 10%; padding-left: 2px;">
                                                        <h5 class="ms-standardheader ms-WPTitle">
                                                            ORG</h5>
                                                    </td>
                                                    <td style="width: 10%; padding-left: 2px;">
                                                        <h5 class="ms-standardheader ms-WPTitle">
                                                            Wire Cd</h5>
                                                    </td>
                                                    <td style="width: 10%; padding-left: 2px;">
                                                        <h5 class="ms-standardheader ms-WPTitle">
                                                            Check Cd</h5>
                                                    </td>
                                                    <td style="width: 10%; padding-left: 2px;">
                                                        <h5 class="ms-standardheader ms-WPTitle">
                                                            Dest Cd</h5>
                                                    </td>
                                                </tr>
                                        </HeaderTemplate>
                                        <ItemTemplate>
                                            <tr class="alt-background-color">
                                                <td class="ms-vb" style="width: 20%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "BusinessUnit" ) %>
                                                    </div>
                                                </td>
                                                <td class="ms-vb" style="width: 10%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "ORG" ) %>
                                                    </div>
                                                </td>
                                                <td class="ms-vb" style="width: 10%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "WireCode" ) %>
                                                    </div>
                                                </td>
                                                <td class="ms-vb" style="width: 10%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "CheckCode" ) %>
                                                    </div>
                                                </td>
                                                <td class="ms-vb" style="width: 10%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "DestCode" ) %>
                                                    </div>
                                                </td>
                                                <asp:HiddenField ID="uiHiddenGuid" runat="server" Value='<%# DataBinder.Eval( Container.DataItem, "value" ) %>' />
                                            </tr>
                                        </ItemTemplate>
                                        <AlternatingItemTemplate>
                                            <tr>
                                                <td class="ms-vb" style="width: 20%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "BusinessUnit" ) %>
                                                    </div>
                                                </td>
                                                <td class="ms-vb" style="width: 10%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "ORG" ) %>
                                                    </div>
                                                </td>
                                                <td class="ms-vb" style="width: 10%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "WireCode" ) %>
                                                    </div>
                                                </td>
                                                <td class="ms-vb" style="width: 10%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "CheckCode" ) %>
                                                    </div>
                                                </td>
                                                <td class="ms-vb" style="width: 10%;">
                                                    <div style="word-break: break-all;">
                                                        <%# DataBinder.Eval( Container.DataItem, "DestCode" ) %>
                                                    </div>
                                                </td>
                                                <asp:HiddenField ID="uiHiddenGuid" runat="server" Value='<%# DataBinder.Eval( Container.DataItem, "value" ) %>' />
                                            </tr>
                                        </AlternatingItemTemplate>
                                        <FooterTemplate>
                                            </table>
                                        </FooterTemplate>
                                    </asp:Repeater>
                                </td>
                            </tr>
                        </table>
                        <table width="100%">
                            <tr>
                                <td align="left" style="width: 50%; color: Red">
                                    <asp:Label ID="uiLblPromoteMsg" runat="server" Text="Promoting .. "></asp:Label>
                                </td>
                                <td align="right">
                                    <asp:Button ID="uiBtnPromote" runat="server" Text="Promote" OnClick="uiBtnPromote_Click" />&nbsp;&nbsp;<asp:Button
                                        ID="uiBtnCancel" runat="server" Text="Cancel" OnClientClick="closeWin()" />
                                </td>
                            </tr>
                        </table>
                    </div>
                </asp:View>
            </asp:MultiView>
        </asp:Panel>
        <asp:Panel ID="uiMsg" runat="server">
            <table width="100%">
                <tr>
                    <td align="center">
                        <asp:Label ID="uiLblMsg" runat="server" Text="No Items Found" Font-Size="Small"></asp:Label>
                    </td>
                </tr>
            </table>
        </asp:Panel>
    </ContentTemplate>
</asp:UpdatePanel>
